import { createApp } from 'vue'

import App from './App.vue'
import router from "./router"
import bus from "./utils/bus"
import  './assets/el-reset.less'

// 引入路由钩子

import"./utils/routerHome"

//引入全局的less文件
import "./assets/global.less"
//引入Pinia
import { createPinia } from "pinia"
import ElementPlus from 'element-plus'
import 'element-plus/dist/index.css'
let app = createApp(App)
//注册全局组件,所有的组件里面不需要引入都可以使用
// app.component('breadCrumb', breadCrumb)
//将bus添加到全局
// app.config.globalProperties.$bus = bus;
// 引入elementui

// 引入持久化pinia
import piniaPluginPersistedstate from "pinia-plugin-persistedstate"
let pinia = createPinia()
pinia.use(piniaPluginPersistedstate)
app.use(router)
app.use(ElementPlus)
app.mount('#app')
app.use(pinia)

// app.use(createPinia())